package com.share.user.admin.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.List;

/**
 * 登陆返回
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
public class LoginVo implements Serializable {
    /**
     * 头像
     */
    private String avatar;
    /**
     * 用户名
     */
    private String username;
    /**
     * 昵称
     */
    private String nickname;
    /**
     * 用户角色
     */
    private List<String> roles;
    /**
     * 权限
     */
    private List<String> permission;

    private String accessToken;
    private String refreshToken;
    @JsonFormat(pattern = "yyyy/MM/dd HH:mm:ss")
    private LocalDateTime expires;

}
